package com.you.atlas.web.place.module.screen;

import org.springframework.beans.factory.annotation.Autowired;

import com.alibaba.citrus.turbine.Navigator;
import com.alibaba.citrus.turbine.dataresolver.Param;
import com.you.atlas.biz.place.service.NoteService;
import com.you.common.webx.AuthContext;

public class NoteUp {

    @Autowired
    private NoteService noteService;

    public void execute(@Param("noteId") Long noteId, Navigator navigator) {
        noteService.up(noteId, AuthContext.getContext().getMemberId());
        navigator.redirectTo("placeModule").withTarget("noteView.vm").uri().addQueryData("id", noteId);
    }
}
